Get e2fsprogs-1.34.tgz at http://e2fsprogs.sourceforge.net or on TestDisk web page.
cd testdisk tar xzf e2fsprogs-1.34.tgz
In e2fsprogs-1.34/lib/ext2fs/flushb.c
, add at the beginning of the file
before #if HAVE_SYS_MOUNT_H
.
#ifdef HAVE_SYS_PARAM_H #include <sys/param.h> #endif
cd e2fsprogs-1.34; ./configure && make libs
If you want to use another version, don't forget to modify src/Makefile file otherwise TestDisk won't compile.
Get progsreiserfs-0.3.1-rc8.tar.gz at http://reiserfs.osdn.org.ua/
and run ./configure --disable-nls && make
Get ntfsprogs-1.8.2.tar.gz from http://linux-ntfs.sf.net/
tar xzf ntfsprogs-1.8.2.tar.gz cd ntfsprogs-1.8.2
bash ./configure && make libs
To compile TestDisk, run cd src; make bsd
.
TestDisk uses an ncurses interface, so ncurses library and development files must be present.
If you need a small binary for binary distribution, get the UPX packer at http://upx.sourceforge.net/ and run
strip testdisk strip --remove-section=.comment testdisk strip --remove-section=.note testdisk upx -9 testdisk
TestDisk home: http://www.cgsecurity.org/testdisk.html.
Christophe GRENIER grenier@cgsecurity.org